<!DOCTYPE html>
<html lang="zh-CN" dir="ltr">
  <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width,initial-scale=1">
    <title>1.3 搭建Flutter开发环境 | 落光的Pro博客</title>
    <meta name="description" content="Vite & Vue powered static site generator.">
    <link rel="preload stylesheet" href="./assets/style.4b0df91d.css" as="style">
    
    <script type="module" src="./assets/app.0acbd3fd.js"></script>
    <link rel="preload" href="./assets/inter-roman-latin.2ed14f66.woff2" as="font" type="font/woff2" crossorigin="">
    <link rel="modulepreload" href="./assets/chunks/framework.eaf25f5b.js">
    <link rel="modulepreload" href="./assets/chunks/theme.ce44a0e6.js">
    <link rel="modulepreload" href="./assets/largeFrontEnd_flutter_chapter1_install_flutter.md.4543c368.lean.js">
    <script id="check-dark-light">(()=>{const e=localStorage.getItem("vitepress-theme-appearance")||"auto",a=window.matchMedia("(prefers-color-scheme: dark)").matches;(!e||e==="auto"?a:e==="dark")&&document.documentElement.classList.add("dark")})();</script>
  </head>
  <body>
    <div id="app"><div class="Layout" data-v-1919c326><!--[--><!--]--><!--[--><span tabindex="-1" data-v-0f60ec36></span><a href="#VPContent" class="VPSkipLink visually-hidden" data-v-0f60ec36> Skip to content </a><!--]--><!----><header class="VPNav" data-v-1919c326 data-v-7e5bc4a5><div class="VPNavBar has-sidebar" data-v-7e5bc4a5 data-v-a0fd61f4><div class="container" data-v-a0fd61f4><div class="title" data-v-a0fd61f4><div class="VPNavBarTitle has-sidebar" data-v-a0fd61f4 data-v-86d1bed8><a class="title" href="./" data-v-86d1bed8><!--[--><!--]--><!--[--><img class="VPImage logo" src="./icon-radius.png" alt data-v-8426fc1a><!--]--><!--[-->落光的Pro博客<!--]--><!--[--><!--]--></a></div></div><div class="content" data-v-a0fd61f4><div class="curtain" data-v-a0fd61f4></div><div class="content-body" data-v-a0fd61f4><!--[--><!--]--><div class="VPNavBarSearch search" style="--vp-meta-key:&#39;Meta&#39;;" data-v-a0fd61f4><!--[--><!----><div id="local-search"><button type="button" class="DocSearch DocSearch-Button" aria-label="Search"><span class="DocSearch-Button-Container"><svg class="DocSearch-Search-Icon" width="20" height="20" viewBox="0 0 20 20" aria-label="search icon"><path d="M14.386 14.386l4.0877 4.0877-4.0877-4.0877c-2.9418 2.9419-7.7115 2.9419-10.6533 0-2.9419-2.9418-2.9419-7.7115 0-10.6533 2.9418-2.9419 7.7115-2.9419 10.6533 0 2.9419 2.9418 2.9419 7.7115 0 10.6533z" stroke="currentColor" fill="none" fill-rule="evenodd" stroke-linecap="round" stroke-linejoin="round"></path></svg><span class="DocSearch-Button-Placeholder">Search</span></span><span class="DocSearch-Button-Keys"><kbd class="DocSearch-Button-Key"></kbd><kbd class="DocSearch-Button-Key">K</kbd></span></button></div><!--]--></div><nav aria-labelledby="main-nav-aria-label" class="VPNavBarMenu menu" data-v-a0fd61f4 data-v-7f418b0f><span id="main-nav-aria-label" class="visually-hidden" data-v-7f418b0f>Main Navigation</span><!--[--><!--[--><div class="VPFlyout VPNavBarMenuGroup" data-v-7f418b0f data-v-9c007e85><button type="button" class="button" aria-haspopup="true" aria-expanded="false" data-v-9c007e85><span class="text" data-v-9c007e85><!----><span data-v-9c007e85>大前端</span><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="text-icon" data-v-9c007e85><path d="M12,16c-0.3,0-0.5-0.1-0.7-0.3l-6-6c-0.4-0.4-0.4-1,0-1.4s1-0.4,1.4,0l5.3,5.3l5.3-5.3c0.4-0.4,1-0.4,1.4,0s0.4,1,0,1.4l-6,6C12.5,15.9,12.3,16,12,16z"></path></svg></span></button><div class="menu" data-v-9c007e85><div class="VPMenu" data-v-9c007e85 data-v-e7ea1737><div class="items" data-v-e7ea1737><!--[--><!--[--><div class="VPMenuLink" data-v-e7ea1737 data-v-43f1e123><a class="VPLink link" href="./largeFrontEnd/webFrontEnd/md/01.html" data-v-43f1e123><!--[-->Web前端<!--]--></a></div><!--]--><!--[--><div class="VPMenuLink" data-v-e7ea1737 data-v-43f1e123><a class="VPLink link" href="./largeFrontEnd/uniapp/" data-v-43f1e123><!--[-->Uni-app<!--]--></a></div><!--]--><!--[--><div class="VPMenuLink" data-v-e7ea1737 data-v-43f1e123><a class="VPLink link" href="./largeFrontEnd/weChatMiniProgram/" data-v-43f1e123><!--[-->微信小程序<!--]--></a></div><!--]--><!--[--><div class="VPMenuLink" data-v-e7ea1737 data-v-43f1e123><a class="VPLink link" href="./largeFrontEnd/electron/" data-v-43f1e123><!--[-->Electron<!--]--></a></div><!--]--><!--[--><div class="VPMenuLink" data-v-e7ea1737 data-v-43f1e123><a class="VPLink link" href="./largeFrontEnd/flutter/" data-v-43f1e123><!--[-->Flutter<!--]--></a></div><!--]--><!--[--><div class="VPMenuLink" data-v-e7ea1737 data-v-43f1e123><a class="VPLink link" href="./largeFrontEnd/interview/01.html" data-v-43f1e123><!--[-->前端面试题<!--]--></a></div><!--]--><!--]--></div><!--[--><!--]--></div></div></div><!--]--><!--[--><a class="VPLink link VPNavBarMenuLink" href="./backEnd/" tabindex="0" data-v-7f418b0f data-v-42ef59de><!--[--><span data-v-42ef59de>后端</span><!--]--></a><!--]--><!--[--><a class="VPLink link VPNavBarMenuLink" href="./linux/" tabindex="0" data-v-7f418b0f data-v-42ef59de><!--[--><span data-v-42ef59de>Linux</span><!--]--></a><!--]--><!--[--><a class="VPLink link VPNavBarMenuLink" href="./myTeam/" tabindex="0" data-v-7f418b0f data-v-42ef59de><!--[--><span data-v-42ef59de>我的团队</span><!--]--></a><!--]--><!--]--></nav><!----><div class="VPNavBarAppearance appearance" data-v-a0fd61f4 data-v-f6a63727><button class="VPSwitch VPSwitchAppearance" type="button" role="switch" title="toggle dark mode" aria-checked="false" data-v-f6a63727 data-v-ce54a7d1 data-v-b1685198><span class="check" data-v-b1685198><span class="icon" data-v-b1685198><!--[--><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="sun" data-v-ce54a7d1><path d="M12,18c-3.3,0-6-2.7-6-6s2.7-6,6-6s6,2.7,6,6S15.3,18,12,18zM12,8c-2.2,0-4,1.8-4,4c0,2.2,1.8,4,4,4c2.2,0,4-1.8,4-4C16,9.8,14.2,8,12,8z"></path><path d="M12,4c-0.6,0-1-0.4-1-1V1c0-0.6,0.4-1,1-1s1,0.4,1,1v2C13,3.6,12.6,4,12,4z"></path><path d="M12,24c-0.6,0-1-0.4-1-1v-2c0-0.6,0.4-1,1-1s1,0.4,1,1v2C13,23.6,12.6,24,12,24z"></path><path d="M5.6,6.6c-0.3,0-0.5-0.1-0.7-0.3L3.5,4.9c-0.4-0.4-0.4-1,0-1.4s1-0.4,1.4,0l1.4,1.4c0.4,0.4,0.4,1,0,1.4C6.2,6.5,5.9,6.6,5.6,6.6z"></path><path d="M19.8,20.8c-0.3,0-0.5-0.1-0.7-0.3l-1.4-1.4c-0.4-0.4-0.4-1,0-1.4s1-0.4,1.4,0l1.4,1.4c0.4,0.4,0.4,1,0,1.4C20.3,20.7,20,20.8,19.8,20.8z"></path><path d="M3,13H1c-0.6,0-1-0.4-1-1s0.4-1,1-1h2c0.6,0,1,0.4,1,1S3.6,13,3,13z"></path><path d="M23,13h-2c-0.6,0-1-0.4-1-1s0.4-1,1-1h2c0.6,0,1,0.4,1,1S23.6,13,23,13z"></path><path d="M4.2,20.8c-0.3,0-0.5-0.1-0.7-0.3c-0.4-0.4-0.4-1,0-1.4l1.4-1.4c0.4-0.4,1-0.4,1.4,0s0.4,1,0,1.4l-1.4,1.4C4.7,20.7,4.5,20.8,4.2,20.8z"></path><path d="M18.4,6.6c-0.3,0-0.5-0.1-0.7-0.3c-0.4-0.4-0.4-1,0-1.4l1.4-1.4c0.4-0.4,1-0.4,1.4,0s0.4,1,0,1.4l-1.4,1.4C18.9,6.5,18.6,6.6,18.4,6.6z"></path></svg><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="moon" data-v-ce54a7d1><path d="M12.1,22c-0.3,0-0.6,0-0.9,0c-5.5-0.5-9.5-5.4-9-10.9c0.4-4.8,4.2-8.6,9-9c0.4,0,0.8,0.2,1,0.5c0.2,0.3,0.2,0.8-0.1,1.1c-2,2.7-1.4,6.4,1.3,8.4c2.1,1.6,5,1.6,7.1,0c0.3-0.2,0.7-0.3,1.1-0.1c0.3,0.2,0.5,0.6,0.5,1c-0.2,2.7-1.5,5.1-3.6,6.8C16.6,21.2,14.4,22,12.1,22zM9.3,4.4c-2.9,1-5,3.6-5.2,6.8c-0.4,4.4,2.8,8.3,7.2,8.7c2.1,0.2,4.2-0.4,5.8-1.8c1.1-0.9,1.9-2.1,2.4-3.4c-2.5,0.9-5.3,0.5-7.5-1.1C9.2,11.4,8.1,7.7,9.3,4.4z"></path></svg><!--]--></span></span></button></div><div class="VPSocialLinks VPNavBarSocialLinks social-links" data-v-a0fd61f4 data-v-0394ad82 data-v-7bc22406><!--[--><a class="VPSocialLink no-icon" href="https://gitee.com/luoguangguang" aria-label="github" target="_blank" rel="noopener" data-v-7bc22406 data-v-f80f8133><svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>GitHub</title><path d="M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12"/></svg></a><a class="VPSocialLink no-icon" href="..." aria-label="cool link" target="_blank" rel="noopener" data-v-7bc22406 data-v-f80f8133><svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>Dribbble</title><path d="M12...6.38z"/></svg></a><!--]--></div><div class="VPFlyout VPNavBarExtra extra" data-v-a0fd61f4 data-v-40855f84 data-v-9c007e85><button type="button" class="button" aria-haspopup="true" aria-expanded="false" aria-label="extra navigation" data-v-9c007e85><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="icon" data-v-9c007e85><circle cx="12" cy="12" r="2"></circle><circle cx="19" cy="12" r="2"></circle><circle cx="5" cy="12" r="2"></circle></svg></button><div class="menu" data-v-9c007e85><div class="VPMenu" data-v-9c007e85 data-v-e7ea1737><!----><!--[--><!--[--><!----><div class="group" data-v-40855f84><div class="item appearance" data-v-40855f84><p class="label" data-v-40855f84>Appearance</p><div class="appearance-action" data-v-40855f84><button class="VPSwitch VPSwitchAppearance" type="button" role="switch" title="toggle dark mode" aria-checked="false" data-v-40855f84 data-v-ce54a7d1 data-v-b1685198><span class="check" data-v-b1685198><span class="icon" data-v-b1685198><!--[--><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="sun" data-v-ce54a7d1><path d="M12,18c-3.3,0-6-2.7-6-6s2.7-6,6-6s6,2.7,6,6S15.3,18,12,18zM12,8c-2.2,0-4,1.8-4,4c0,2.2,1.8,4,4,4c2.2,0,4-1.8,4-4C16,9.8,14.2,8,12,8z"></path><path d="M12,4c-0.6,0-1-0.4-1-1V1c0-0.6,0.4-1,1-1s1,0.4,1,1v2C13,3.6,12.6,4,12,4z"></path><path d="M12,24c-0.6,0-1-0.4-1-1v-2c0-0.6,0.4-1,1-1s1,0.4,1,1v2C13,23.6,12.6,24,12,24z"></path><path d="M5.6,6.6c-0.3,0-0.5-0.1-0.7-0.3L3.5,4.9c-0.4-0.4-0.4-1,0-1.4s1-0.4,1.4,0l1.4,1.4c0.4,0.4,0.4,1,0,1.4C6.2,6.5,5.9,6.6,5.6,6.6z"></path><path d="M19.8,20.8c-0.3,0-0.5-0.1-0.7-0.3l-1.4-1.4c-0.4-0.4-0.4-1,0-1.4s1-0.4,1.4,0l1.4,1.4c0.4,0.4,0.4,1,0,1.4C20.3,20.7,20,20.8,19.8,20.8z"></path><path d="M3,13H1c-0.6,0-1-0.4-1-1s0.4-1,1-1h2c0.6,0,1,0.4,1,1S3.6,13,3,13z"></path><path d="M23,13h-2c-0.6,0-1-0.4-1-1s0.4-1,1-1h2c0.6,0,1,0.4,1,1S23.6,13,23,13z"></path><path d="M4.2,20.8c-0.3,0-0.5-0.1-0.7-0.3c-0.4-0.4-0.4-1,0-1.4l1.4-1.4c0.4-0.4,1-0.4,1.4,0s0.4,1,0,1.4l-1.4,1.4C4.7,20.7,4.5,20.8,4.2,20.8z"></path><path d="M18.4,6.6c-0.3,0-0.5-0.1-0.7-0.3c-0.4-0.4-0.4-1,0-1.4l1.4-1.4c0.4-0.4,1-0.4,1.4,0s0.4,1,0,1.4l-1.4,1.4C18.9,6.5,18.6,6.6,18.4,6.6z"></path></svg><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="moon" data-v-ce54a7d1><path d="M12.1,22c-0.3,0-0.6,0-0.9,0c-5.5-0.5-9.5-5.4-9-10.9c0.4-4.8,4.2-8.6,9-9c0.4,0,0.8,0.2,1,0.5c0.2,0.3,0.2,0.8-0.1,1.1c-2,2.7-1.4,6.4,1.3,8.4c2.1,1.6,5,1.6,7.1,0c0.3-0.2,0.7-0.3,1.1-0.1c0.3,0.2,0.5,0.6,0.5,1c-0.2,2.7-1.5,5.1-3.6,6.8C16.6,21.2,14.4,22,12.1,22zM9.3,4.4c-2.9,1-5,3.6-5.2,6.8c-0.4,4.4,2.8,8.3,7.2,8.7c2.1,0.2,4.2-0.4,5.8-1.8c1.1-0.9,1.9-2.1,2.4-3.4c-2.5,0.9-5.3,0.5-7.5-1.1C9.2,11.4,8.1,7.7,9.3,4.4z"></path></svg><!--]--></span></span></button></div></div></div><div class="group" data-v-40855f84><div class="item social-links" data-v-40855f84><div class="VPSocialLinks social-links-list" data-v-40855f84 data-v-7bc22406><!--[--><a class="VPSocialLink no-icon" href="https://gitee.com/luoguangguang" aria-label="github" target="_blank" rel="noopener" data-v-7bc22406 data-v-f80f8133><svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>GitHub</title><path d="M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12"/></svg></a><a class="VPSocialLink no-icon" href="..." aria-label="cool link" target="_blank" rel="noopener" data-v-7bc22406 data-v-f80f8133><svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>Dribbble</title><path d="M12...6.38z"/></svg></a><!--]--></div></div></div><!--]--><!--]--></div></div></div><!--[--><!--]--><button type="button" class="VPNavBarHamburger hamburger" aria-label="mobile navigation" aria-expanded="false" aria-controls="VPNavScreen" data-v-a0fd61f4 data-v-e5dd9c1c><span class="container" data-v-e5dd9c1c><span class="top" data-v-e5dd9c1c></span><span class="middle" data-v-e5dd9c1c></span><span class="bottom" data-v-e5dd9c1c></span></span></button></div></div></div></div><!----></header><div class="VPLocalNav reached-top" data-v-1919c326 data-v-79c8c1df><button class="menu" aria-expanded="false" aria-controls="VPSidebarNav" data-v-79c8c1df><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="menu-icon" data-v-79c8c1df><path d="M17,11H3c-0.6,0-1-0.4-1-1s0.4-1,1-1h14c0.6,0,1,0.4,1,1S17.6,11,17,11z"></path><path d="M21,7H3C2.4,7,2,6.6,2,6s0.4-1,1-1h18c0.6,0,1,0.4,1,1S21.6,7,21,7z"></path><path d="M21,15H3c-0.6,0-1-0.4-1-1s0.4-1,1-1h18c0.6,0,1,0.4,1,1S21.6,15,21,15z"></path><path d="M17,19H3c-0.6,0-1-0.4-1-1s0.4-1,1-1h14c0.6,0,1,0.4,1,1S17.6,19,17,19z"></path></svg><span class="menu-text" data-v-79c8c1df>Menu</span></button><div class="VPLocalNavOutlineDropdown" style="--vp-vh:0px;" data-v-79c8c1df data-v-1c15a60a><button data-v-1c15a60a>Return to top</button><!----></div></div><aside class="VPSidebar" data-v-1919c326 data-v-b00e2fdd><div class="curtain" data-v-b00e2fdd></div><nav class="nav" id="VPSidebarNav" aria-labelledby="sidebar-aria-label" tabindex="-1" data-v-b00e2fdd><span class="visually-hidden" id="sidebar-aria-label" data-v-b00e2fdd> Sidebar Navigation </span><!--[--><!--]--><!--[--><div class="group" data-v-b00e2fdd><section class="VPSidebarItem level-0 collapsible" data-v-b00e2fdd data-v-e31bd47b><div class="item" role="button" tabindex="0" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><h2 class="text" data-v-e31bd47b>Flutter入门到实战</h2><div class="caret" role="button" aria-label="toggle section" tabindex="0" data-v-e31bd47b><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="caret-icon" data-v-e31bd47b><path d="M9,19c-0.3,0-0.5-0.1-0.7-0.3c-0.4-0.4-0.4-1,0-1.4l5.3-5.3L8.3,6.7c-0.4-0.4-0.4-1,0-1.4s1-0.4,1.4,0l6,6c0.4,0.4,0.4,1,0,1.4l-6,6C9.5,18.9,9.3,19,9,19z"></path></svg></div></div><div class="items" data-v-e31bd47b><!--[--><div class="VPSidebarItem level-1 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="./largeFrontEnd/flutter/chapter1/index.html" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>第一章 初识Flutter</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-1 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="./largeFrontEnd/flutter/chapter2/index.html" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>第二章 简介</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-1 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="./largeFrontEnd/flutter/chapter3/index.html" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>第三章 基础组件</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-1 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="./largeFrontEnd/flutter/chapter4/index.html" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>第四章 布局类组件</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-1 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="./largeFrontEnd/flutter/chapter5/index.html" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>第五章 容器类Widget</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-1 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="./largeFrontEnd/flutter/chapter6/index.html" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>第六章 可滚动组件</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-1 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="./largeFrontEnd/flutter/chapter7/index.html" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>第七章 功能型Widget简介</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-1 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="./largeFrontEnd/flutter/chapter8/index.html" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>第八章 事件处理与通知</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-1 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="./largeFrontEnd/flutter/chapter9/index.html" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>第九章 动画</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-1 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="./largeFrontEnd/flutter/chapter10/index.html" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>第十章 自定义组件</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-1 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="./largeFrontEnd/flutter/chapter11/index.html" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>第十一章 文件操作</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-1 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="./largeFrontEnd/flutter/chapter12/index.html" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>第十二章 Flutter 扩展</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-1 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="./largeFrontEnd/flutter/chapter13/index.html" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>第十三章 多语言</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-1 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="./largeFrontEnd/flutter/chapter14/index.html" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>第十四章 高级进阶</p><!--]--></a><!----></div><!----></div><!--]--></div></section></div><!--]--><!--[--><!--]--></nav></aside><div class="VPContent has-sidebar" id="VPContent" data-v-1919c326 data-v-669faec9><div class="VPDoc has-sidebar has-aside" data-v-669faec9 data-v-6b87e69f><!--[--><!--]--><div class="container" data-v-6b87e69f><div class="aside" data-v-6b87e69f><div class="aside-curtain" data-v-6b87e69f></div><div class="aside-container" data-v-6b87e69f><div class="aside-content" data-v-6b87e69f><div class="VPDocAside" data-v-6b87e69f data-v-3f215769><!--[--><!--]--><!--[--><!--]--><div class="VPDocAsideOutline" role="navigation" data-v-3f215769 data-v-6ae8e080><div class="content" data-v-6ae8e080><div class="outline-marker" data-v-6ae8e080></div><div class="outline-title" role="heading" data-v-6ae8e080>On this page</div><nav aria-labelledby="doc-outline-aria-label" data-v-6ae8e080><span class="visually-hidden" id="doc-outline-aria-label" data-v-6ae8e080> Table of Contents for current page </span><ul class="root" data-v-6ae8e080 data-v-d0ee3533><!--[--><!--]--></ul></nav></div></div><!--[--><!--]--><div class="spacer" data-v-3f215769></div><!--[--><!--]--><div class="VPDocAsideCarbonAds" data-v-3f215769><div class="VPCarbonAds" data-v-2e1efd59></div></div><!--[--><!--]--><!--[--><!--]--></div></div></div></div><div class="content" data-v-6b87e69f><div class="content-container" data-v-6b87e69f><!--[--><!--]--><!----><main class="main" data-v-6b87e69f><div style="position:relative;" class="vp-doc _largeFrontEnd_flutter_chapter1_install_flutter" data-v-6b87e69f><div><h1 id="_1-3-搭建flutter开发环境" tabindex="-1">1.3 搭建Flutter开发环境 <a class="header-anchor" href="#_1-3-搭建flutter开发环境" aria-label="Permalink to &quot;1.3 搭建Flutter开发环境&quot;">​</a></h1><p>工欲善其事必先利其器，本节首先会分别介绍一下在Windows和macOS下Flutter SDK的安装，然后再介绍一下配IDE和模拟器的使用。</p><h2 id="_1-3-1-安装flutter" tabindex="-1">1.3.1 安装Flutter <a class="header-anchor" href="#_1-3-1-安装flutter" aria-label="Permalink to &quot;1.3.1 安装Flutter&quot;">​</a></h2><p>由于Flutter会同时构建Android和IOS两个平台的发布包，所以Flutter同时依赖Android SDK和iOS SDK，在安装Flutter时也需要安装相应平台的构建工具和SDK。下面我们分别介绍一下Windows和macOS下的环境搭建。</p><blockquote><p>注意：本节介绍的安装方式随着Flutter的升级可能会发生变化，如果下面介绍的内容在您安装Flutter时已经失效，请访问Flutter官网，按照官网最新的安装教程安装。</p></blockquote><h3 id="_1-使用镜像" tabindex="-1">1. 使用镜像 <a class="header-anchor" href="#_1-使用镜像" aria-label="Permalink to &quot;1. 使用镜像&quot;">​</a></h3><p>由于在国内访问Flutter有时可能会受到限制，Flutter官方为中国开发者搭建了临时镜像，大家可以将如下环境变量添加到到用户环境变量中：</p><div class="language- vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang"></span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#e1e4e8;">export PUB_HOSTED_URL=https://pub.flutter-io.cn</span></span>
<span class="line"><span style="color:#e1e4e8;">export FLUTTER_STORAGE_BASE_URL=https://storage.flutter-io.cn</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#24292e;">export PUB_HOSTED_URL=https://pub.flutter-io.cn</span></span>
<span class="line"><span style="color:#24292e;">export FLUTTER_STORAGE_BASE_URL=https://storage.flutter-io.cn</span></span></code></pre></div><p><strong>注意：</strong> 此镜像为临时镜像，并不能保证一直可用，读者可以参考<a href="https://flutter.dev/community/china" target="_blank" rel="noreferrer">https://flutter.dev/community/china</a> 以获得有关镜像服务器的最新动态。</p><h3 id="_2-在windows上搭建flutter开发环境" tabindex="-1">2. 在Windows上搭建Flutter开发环境 <a class="header-anchor" href="#_2-在windows上搭建flutter开发环境" aria-label="Permalink to &quot;2. 在Windows上搭建Flutter开发环境&quot;">​</a></h3><h4 id="_1-系统要求" tabindex="-1">1）系统要求 <a class="header-anchor" href="#_1-系统要求" aria-label="Permalink to &quot;1）系统要求&quot;">​</a></h4><p>要安装并运行Flutter，您的开发环境必须满足以下最低要求:</p><ul><li><p>操作系统: Windows 7 或更高版本 (64-bit)</p></li><li><p>磁盘空间: 400 MB (不包括Android Studio的磁盘空间).</p></li><li><p>工具: Flutter 依赖下面这些命令行工具.</p><ul><li><p><a href="https://docs.microsoft.com/en-us/powershell/scripting/setup/installing-windows-powershell#upgrading-existing-windows-powershell" target="_blank" rel="noreferrer">PowerShell 5.0</a> 或更新的版本</p></li><li><p><a href="https://git-scm.com/download/win" target="_blank" rel="noreferrer">Git for Windows</a>  (Git命令行工具)；</p></li></ul><p>如果已安装Git for Windows，请确保可以在命令提示符或PowerShell中运行 git 命令</p></li></ul><h4 id="_2-获取flutter-sdk" tabindex="-1">2）获取Flutter SDK <a class="header-anchor" href="#_2-获取flutter-sdk" aria-label="Permalink to &quot;2）获取Flutter SDK&quot;">​</a></h4><ol><li><p>去flutter官网下载其最新可用的安装包，下载地址：<a href="https://flutter.dev/docs/development/tools/sdk/releases" target="_blank" rel="noreferrer">https://flutter.dev/docs/development/tools/sdk/releases</a> 。</p><p>注意，Flutter的渠道版本会不停变动，请以Flutter官网为准。另外，在中国大陆地区，要想正常获取安装包列表或下载安装包，可能需要翻墙，读者也可以去Flutter github项目下去下载安装包，地址：<a href="https://github.com/flutter/flutter/releases" target="_blank" rel="noreferrer">https://github.com/flutter/flutter/releases</a> 。</p></li><li><p>将安装包zip解压到你想安装Flutter SDK的路径（如：<code>C:\src\flutter</code>；注意，<strong>不要</strong>将flutter安装到需要一些高权限的路径如<code>C:\Program Files\</code>）。</p></li><li><p>在Flutter安装目录的<code>flutter</code>文件下找到<code>flutter_console.bat</code>，双击运行并启动<strong>flutter命令行</strong>，接下来，你就可以在Flutter命令行运行flutter命令了。</p></li></ol><h5 id="更新环境变量" tabindex="-1">更新环境变量 <a class="header-anchor" href="#更新环境变量" aria-label="Permalink to &quot;更新环境变量&quot;">​</a></h5><p>如果你想在Windows系统自带命令行运行flutter命令，需要添加以下环境变量到用户PATH：</p><ul><li>在开始菜单的搜索功能键入“env”，然后选择 编辑系统环境变量</li><li>在“用户变量”下检查是否有名为“Path”的条目: <ul><li>如果该条目存在， 追加 flutter\bin的全路径，使用 ; 作为分隔符.</li><li>如果该条目不存在，创建一个新用户变量 Path ，然后将 <code>flutter\bin</code> 的全路径作为它的值.</li></ul></li></ul><p>重启Windows以应用此更改.</p><h5 id="运行-flutter-doctor命令" tabindex="-1">运行 flutter doctor命令 <a class="header-anchor" href="#运行-flutter-doctor命令" aria-label="Permalink to &quot;运行 flutter doctor命令&quot;">​</a></h5><p>在Flutter命令行运行如下命令来查看是否还需要安装其他依赖，如果需要，安装它们：</p><div class="language-shell vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang">shell</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#B392F0;">flutter</span><span style="color:#E1E4E8;"> </span><span style="color:#9ECBFF;">doctor</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#6F42C1;">flutter</span><span style="color:#24292E;"> </span><span style="color:#032F62;">doctor</span></span></code></pre></div><p>该命令检查你的环境并在命令行窗口中显示报告。Dart SDK已经在打包在Flutter SDK里了，没有必要单独安装Dart。 仔细检查命令行输出以获取可能需要安装的其他软件或进一步需要执行的任务。</p><p>例如：</p><div class="language- vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang"></span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#e1e4e8;">[-] Android toolchain - develop for Android devices</span></span>
<span class="line"><span style="color:#e1e4e8;">    • Android SDK at D:\Android\sdk</span></span>
<span class="line"><span style="color:#e1e4e8;">    ✗ Android SDK is missing command line tools; download from https://goo.gl/XxQghQ</span></span>
<span class="line"><span style="color:#e1e4e8;">    • Try re-installing or updating your Android SDK,</span></span>
<span class="line"><span style="color:#e1e4e8;">      visit https://flutter.dev/setup/#android-setup for detailed instructions.</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#24292e;">[-] Android toolchain - develop for Android devices</span></span>
<span class="line"><span style="color:#24292e;">    • Android SDK at D:\Android\sdk</span></span>
<span class="line"><span style="color:#24292e;">    ✗ Android SDK is missing command line tools; download from https://goo.gl/XxQghQ</span></span>
<span class="line"><span style="color:#24292e;">    • Try re-installing or updating your Android SDK,</span></span>
<span class="line"><span style="color:#24292e;">      visit https://flutter.dev/setup/#android-setup for detailed instructions.</span></span></code></pre></div><p>第一次运行flutter命令（如<code>flutter doctor</code>）时，它会下载它自己的依赖项并自行编译。以后再运行就会快得多。缺失的依赖需要安装一下，安装完成后再运行<code>flutter doctor</code>命令来验证是否安装成功。</p><h4 id="_3-android设置" tabindex="-1">3）Android设置 <a class="header-anchor" href="#_3-android设置" aria-label="Permalink to &quot;3）Android设置&quot;">​</a></h4><p>Flutter依赖于Android Studio的全量安装。Android Studio不仅可以管理Android 平台依赖、SDK版本等，而且它也是Flutter开发推荐的IDE之一（当然，你也可以使用其他编辑器或IDE，我们将会在后面讨论）。</p><h5 id="安装android-studio" tabindex="-1">安装Android Studio <a class="header-anchor" href="#安装android-studio" aria-label="Permalink to &quot;安装Android Studio&quot;">​</a></h5><ol><li>下载并安装 Android Studio，下载地址：<a href="https://developer.android.com/studio/index.html" target="_blank" rel="noreferrer">https://developer.android.com/studio/index.html</a> 。</li><li>启动Android Studio，然后执行“Android Studio安装向导”。这将安装最新的Android SDK、Android SDK平台工具和Android SDK构建工具，这些是用Flutter进行Android开发所需要的。</li></ol><h4 id="_4-安装遇到问题" tabindex="-1">4）安装遇到问题？ <a class="header-anchor" href="#_4-安装遇到问题" aria-label="Permalink to &quot;4）安装遇到问题？&quot;">​</a></h4><p>如果在安装过程中遇到问题，可以先去flutter官网查看一下安装方式是否发生变化，或者在网上搜索一下解决方案。</p><h3 id="_3-在macos上搭建flutter开发环境" tabindex="-1">3. 在macOS上搭建Flutter开发环境 <a class="header-anchor" href="#_3-在macos上搭建flutter开发环境" aria-label="Permalink to &quot;3. 在macOS上搭建Flutter开发环境&quot;">​</a></h3><p>在masOS下可以同时进行Android和iOS设备的测试。</p><h4 id="_1-系统要求-1" tabindex="-1">1）系统要求 <a class="header-anchor" href="#_1-系统要求-1" aria-label="Permalink to &quot;1）系统要求&quot;">​</a></h4><p>要安装并运行Flutter，您的开发环境必须满足以下最低要求:</p><ul><li>操作系统: macOS (64-bit)</li><li>磁盘空间: 700 MB (不包括Xcode或Android Studio的磁盘空间）.</li><li>工具: Flutter 依赖下面这些命令行工具. <ul><li><code>bash、mkdir、rm、git、curl、unzip、which</code></li></ul></li></ul><h4 id="_2-获取flutter-sdk-1" tabindex="-1">2）获取Flutter SDK <a class="header-anchor" href="#_2-获取flutter-sdk-1" aria-label="Permalink to &quot;2）获取Flutter SDK&quot;">​</a></h4><ol><li><p>去flutter官网下载其最新可用的安装包，官网地址：<a href="https://flutter.dev/sdk-archive/#macos" target="_blank" rel="noreferrer">https://flutter.dev/sdk-archive/#macos</a></p><p>注意，Flutter的渠道版本会不停变动，请以Flutter官网为准。另外，在中国大陆地区，要想正常获取安装包列表或下载安装包，可能需要翻墙，读者也可以去Flutter github项目下去下载安装包，地址：<a href="https://github.com/flutter/flutter/releases" target="_blank" rel="noreferrer">https://github.com/flutter/flutter/releases</a> 。</p></li><li><p>解压安装包到你想安装的目录，如：</p><div class="language-shell vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang">shell</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#79B8FF;">cd</span><span style="color:#E1E4E8;"> </span><span style="color:#9ECBFF;">~/development</span></span>
<span class="line"><span style="color:#B392F0;">unzip</span><span style="color:#E1E4E8;"> </span><span style="color:#9ECBFF;">~/Downloads/flutter_macos_v0.5.1-beta.zip</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#005CC5;">cd</span><span style="color:#24292E;"> </span><span style="color:#032F62;">~/development</span></span>
<span class="line"><span style="color:#6F42C1;">unzip</span><span style="color:#24292E;"> </span><span style="color:#032F62;">~/Downloads/flutter_macos_v0.5.1-beta.zip</span></span></code></pre></div></li><li><p>添加<code>flutter</code>相关工具到path中：</p><div class="language-shell vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang">shell</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> PATH</span><span style="color:#F97583;">=</span><span style="color:#9ECBFF;">`</span><span style="color:#79B8FF;">pwd</span><span style="color:#9ECBFF;">`/flutter/bin:</span><span style="color:#E1E4E8;">$PATH</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> PATH</span><span style="color:#D73A49;">=</span><span style="color:#032F62;">`</span><span style="color:#005CC5;">pwd</span><span style="color:#032F62;">`/flutter/bin:</span><span style="color:#24292E;">$PATH</span></span></code></pre></div><p>此代码只能暂时针对当前命令行窗口设置PATH环境变量，要想永久将Flutter添加到PATH中请参考下面<strong>更新环境变量</strong> 部分。</p></li></ol><h5 id="运行-flutter-doctor命令-1" tabindex="-1">运行 flutter doctor命令 <a class="header-anchor" href="#运行-flutter-doctor命令-1" aria-label="Permalink to &quot;运行 flutter doctor命令&quot;">​</a></h5><p>这一步和Windows下步骤一致，不再赘述。</p><h5 id="更新环境变量-1" tabindex="-1">更新环境变量 <a class="header-anchor" href="#更新环境变量-1" aria-label="Permalink to &quot;更新环境变量&quot;">​</a></h5><p>将Flutter添加到PATH中，可以在任何终端会话中运行<code>flutter</code>命令。</p><p>对于所有终端会话永久修改此变量的步骤是和特定计算机系统相关的。通常，您会在打开新窗口时将设置环境变量的命令添加到执行的文件中。例如</p><ol><li><p>确定您Flutter SDK的目录记为“FLUTTER_INSTALL_PATH”，您将在后面配置中用到。</p></li><li><p>打开(或创建) <code>$HOME/.bash_profile</code>。文件路径和文件名可能在你的电脑上不同.</p></li><li><p>添加以下路径:</p><div class="language-shell vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang">shell</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> PATH</span><span style="color:#F97583;">=</span><span style="color:#9ECBFF;">[FLUTTER_INSTALL_PATH]/flutter/bin:</span><span style="color:#E1E4E8;">$PATH</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> PATH</span><span style="color:#D73A49;">=</span><span style="color:#032F62;">[FLUTTER_INSTALL_PATH]/flutter/bin:</span><span style="color:#24292E;">$PATH</span></span></code></pre></div><p>例如笔者Flutter 安装目录是“~/code/flutter_dir”，那么代码为：</p><div class="language- vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang"></span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#e1e4e8;">export PATH=~/code/flutter_dir/flutter/bin:$PATH</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#24292e;">export PATH=~/code/flutter_dir/flutter/bin:$PATH</span></span></code></pre></div></li><li><p>运行 <code>source $HOME/.bash_profile</code> 刷新当前终端窗口。</p><blockquote><p><strong>注意:</strong> 如果你使用终端是zsh，终端启动时 <code>~/.bash_profile</code> 将不会被加载，解决办法就是修改 <code>～/.zshrc</code> ，在其中添加：source ～/.bash_profile</p></blockquote></li><li><p>验证“flutter/bin”是否已在PATH中：</p><div class="language- vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang"></span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#e1e4e8;">echo $PATH</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#24292e;">echo $PATH</span></span></code></pre></div></li></ol><h4 id="_3-安装-xcode" tabindex="-1">3）安装 Xcode <a class="header-anchor" href="#_3-安装-xcode" aria-label="Permalink to &quot;3）安装 Xcode&quot;">​</a></h4><p>要为iOS开发Flutter应用程序，您需要Xcode最新版本:</p><ol><li>安装Xcode最新版本。</li><li>配置Xcode命令行工具以使用新安装的Xcode版本 <code>sudo xcode-select --switch /Applications/Xcode.app/Contents/Developer</code> 对于大多数情况，当您想要使用最新版本的Xcode时，这是正确的路径。如果您需要使用不同的版本，请指定相应路径。</li><li>确保Xcode许可协议是通过打开一次Xcode或通过命令<code>sudo xcodebuild -license</code>同意过了.</li></ol><p>使用Xcode，您可以在iOS设备或模拟器上运行Flutter应用程序。</p><h4 id="_4-安装android-studio" tabindex="-1">4）安装Android Studio <a class="header-anchor" href="#_4-安装android-studio" aria-label="Permalink to &quot;4）安装Android Studio&quot;">​</a></h4><p>和Windows一样，要在Android设备上构建并运行Flutter程序都需要先安装Android Studio，读者可以先自行下载并安装Android Studio，在此不再赘述。</p><h3 id="_4-升级-flutter" tabindex="-1">4. 升级 Flutter <a class="header-anchor" href="#_4-升级-flutter" aria-label="Permalink to &quot;4. 升级 Flutter&quot;">​</a></h3><h4 id="_1-flutter-sdk分支" tabindex="-1">1) Flutter SDK分支 <a class="header-anchor" href="#_1-flutter-sdk分支" aria-label="Permalink to &quot;1) Flutter SDK分支&quot;">​</a></h4><p>Flutter SDK有多个分支，如beta、dev、master、stable，其中stable分支为稳定分支（日后有新的稳定版本发布后可能也会有新的稳定分支，如1.0.0），dev和master为开发分支，安装flutter后，你可以运行<code>flutter channel</code>查看所有分支，如笔者本地运行后，结果如下：</p><div class="language- vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang"></span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#e1e4e8;">Flutter channels:</span></span>
<span class="line"><span style="color:#e1e4e8;">  beta</span></span>
<span class="line"><span style="color:#e1e4e8;">  dev</span></span>
<span class="line"><span style="color:#e1e4e8;">* master</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#24292e;">Flutter channels:</span></span>
<span class="line"><span style="color:#24292e;">  beta</span></span>
<span class="line"><span style="color:#24292e;">  dev</span></span>
<span class="line"><span style="color:#24292e;">* master</span></span></code></pre></div><p>带&quot;*&quot;号的分支即你本地的Flutter SDK 跟踪的分支，要切换分支，可以使用<code>flutter channel beta</code> 或 <code>flutter channel master</code>，Flutter官方建议跟踪稳定分支，但你也可以跟踪<code>master</code>分支，这样可以查看最新的变化，但这样稳定性要低得多。</p><h4 id="_2-升级flutter-sdk和依赖包" tabindex="-1">2) 升级Flutter SDK和依赖包 <a class="header-anchor" href="#_2-升级flutter-sdk和依赖包" aria-label="Permalink to &quot;2) 升级Flutter SDK和依赖包&quot;">​</a></h4><p>要升级flutter sdk，只需一句命令：</p><div class="language-shell vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang">shell</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#B392F0;">flutter</span><span style="color:#E1E4E8;"> </span><span style="color:#9ECBFF;">upgrade</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#6F42C1;">flutter</span><span style="color:#24292E;"> </span><span style="color:#032F62;">upgrade</span></span></code></pre></div><p>该命令会同时更新Flutter SDK和你的flutter项目依赖包。如果你只想更新项目依赖包（不包括Flutter SDK），可以使用如下命令：</p><ul><li><code>flutter packages get</code>获取项目所有的依赖包。</li><li><code>flutter packages upgrade</code> 获取项目所有依赖包的最新版本。</li></ul><h2 id="_1-3-2-ide配置与使用" tabindex="-1">1.3.2 IDE配置与使用 <a class="header-anchor" href="#_1-3-2-ide配置与使用" aria-label="Permalink to &quot;1.3.2 IDE配置与使用&quot;">​</a></h2><p>理论上可以使用任何文本编辑器与命令行工具来构建Flutter应用程序。 不过，Flutter官方建议使用Android Studio和VS Code之一以获得更好的开发体验。Flutter官方提供了这两款编辑器插件，通过IDE和插件可获得代码补全、语法高亮、widget编辑辅助、运行和调试支持等功能，可以帮助我们极大地提高开发效率。下面我们分别介绍一下Android Studio和VS Code的配置及使用（Android Studio和VS Code读者可以在其官网获得最新的安装，由于安装比较简单，故不再赘述）。</p><h3 id="_1-android-studio-配置与使用" tabindex="-1">1. Android Studio 配置与使用 <a class="header-anchor" href="#_1-android-studio-配置与使用" aria-label="Permalink to &quot;1. Android Studio 配置与使用&quot;">​</a></h3><p>由于Android Studio是基于IntelliJ IDEA开发的，所以读者也可以使用IntelliJ IDEA。</p><h4 id="_1-安装flutter和dart插件" tabindex="-1">1）安装Flutter和Dart插件 <a class="header-anchor" href="#_1-安装flutter和dart插件" aria-label="Permalink to &quot;1）安装Flutter和Dart插件&quot;">​</a></h4><p>需要安装两个插件:</p><ul><li><code>Flutter</code>插件： 支持Flutter开发工作流 (运行、调试、热重载等)。</li><li><code>Dart</code>插件： 提供代码分析 (输入代码时进行验证、代码补全等)。</li></ul><p>安装步骤：</p><ol><li>启动Android Studio。</li><li>打开插件首选项 (macOS：<strong>Preferences&gt;Plugins</strong>, Windows：<strong>File&gt;Settings&gt;Plugins</strong>)。</li><li>选择 <strong>Browse repositories…</strong>，选择 flutter 插件并点击 <code>install</code>。</li><li>重启Android Studio后插件生效。</li></ol><p>接下来，让我们用Android Studio创建一个Flutter项目，然后运行它，并体验“热重载”。</p><h4 id="_2-创建flutter应用" tabindex="-1">2）创建Flutter应用 <a class="header-anchor" href="#_2-创建flutter应用" aria-label="Permalink to &quot;2）创建Flutter应用&quot;">​</a></h4><ol><li>选择 <strong>File&gt;New Flutter Project</strong> 。</li><li>选择 <strong>Flutter application</strong> 作为 project 类型, 然后点击 Next。</li><li>输入项目名称 (如 <code>myapp</code>)，然后点击 Next。</li><li>点击 <strong>Finish</strong>。</li><li>等待Android Studio安装SDK并创建项目。</li></ol><p>上述命令创建一个Flutter项目，项目名为myapp，其中包含一个使用<a href="https://material.io/guidelines/" target="_blank" rel="noreferrer">Material 组件</a>的简单演示应用程序。</p><p>在项目目录中，您应用程序的代码位于 <code>lib/main.dart</code>。</p><h4 id="_3-运行应用程序" tabindex="-1">3）运行应用程序 <a class="header-anchor" href="#_3-运行应用程序" aria-label="Permalink to &quot;3）运行应用程序&quot;">​</a></h4><ol><li><p>定位到Android Studio工具栏，如图1-2所示：</p><p><img src="/assets/1-2.55e6f5ef.png" alt="图1-3"></p></li><li><p>在 <strong>target selector</strong> 中, 选择一个运行该应用的Android设备。如果没有列出可用，请选择 <strong>Tools&gt;Android&gt;AVD Manager</strong> 并在那里创建一个。</p></li><li><p>在工具栏中点击 <strong>Run图标</strong>。</p></li><li><p>如果一切正常, 您应该在您的设备或模拟器上会看到启动的应用程序，如图1-3：</p><p><img src="/assets/1-3.46465454.png" alt="图1-4"></p></li></ol><h4 id="_4-体验热重载" tabindex="-1">4）体验热重载 <a class="header-anchor" href="#_4-体验热重载" aria-label="Permalink to &quot;4）体验热重载&quot;">​</a></h4><p>Flutter 可以通过 <em>热重载（hot reload）</em> 实现快速的开发周期，热重载就是无需重启应用程序就能实时加载修改后的代码，并且不会丢失状态。简单的对代码进行更改，然后告诉IDE或命令行工具你需要重新加载（点击reload按钮），你就会在你的设备或模拟器上看到更改。</p><ol><li><p>打开<code>lib/main.dart</code>文件</p></li><li><p>将字符串 <code>&#39;You have pushed the button this many times:&#39;</code> 更改为 <code>&#39;You have clicked the button this many times:&#39;</code></p></li><li><p>不要按“停止”按钮; 让您的应用继续运行.</p></li><li><p>要查更改，请调用 <strong>Save</strong> (<code>cmd-s</code> / <code>ctrl-s</code>)，或者点击 <strong>热重载按钮</strong> (带有闪电⚡️图标的按钮)。</p><p>你会立即在运行的应用程序中看到更新的字符串。</p></li></ol><h3 id="_2-vs-code的配置与使用" tabindex="-1">2. VS Code的配置与使用 <a class="header-anchor" href="#_2-vs-code的配置与使用" aria-label="Permalink to &quot;2. VS Code的配置与使用&quot;">​</a></h3><p>VS Code是一个轻量级编辑器，支持Flutter运行和调试。</p><h4 id="_1-安装flutter插件" tabindex="-1">1）安装flutter插件 <a class="header-anchor" href="#_1-安装flutter插件" aria-label="Permalink to &quot;1）安装flutter插件&quot;">​</a></h4><ol><li>启动 VS Code。</li><li>调用 <strong>View&gt;Command Palette…</strong>。</li><li>输入 ‘install’, 然后选择 <strong>Extensions: Install Extension</strong> action。</li><li>在搜索框输入 <code>flutter</code> ，在搜索结果列表中选择 ‘Flutter’, 然后点击 <strong>Install</strong>。</li><li>选择 ‘OK’ 重新启动 VS Code。</li><li>验证配置 <ul><li>调用 <strong>View&gt;Command Palette…</strong></li><li>输入 ‘doctor’, 然后选择 <strong>‘Flutter: Run Flutter Doctor’</strong> action。</li><li>查看“OUTPUT”窗口中的输出是否有问题</li></ul></li></ol><h4 id="_2-创建flutter应用-1" tabindex="-1">2）创建Flutter应用 <a class="header-anchor" href="#_2-创建flutter应用-1" aria-label="Permalink to &quot;2）创建Flutter应用&quot;">​</a></h4><ol><li>启动 VS Code</li><li>调用 <strong>View&gt;Command Palette…</strong></li><li>输入 ‘flutter’, 然后选择 <strong>‘Flutter: New Project’</strong> action</li><li>输入 Project 名称 (如<code>myapp</code>), 然后按回车键</li><li>指定放置项目的位置，然后按蓝色的确定按钮</li><li>等待项目创建继续，并显示main.dart文件</li></ol><h4 id="_3-体验热重载" tabindex="-1">3）体验热重载 <a class="header-anchor" href="#_3-体验热重载" aria-label="Permalink to &quot;3）体验热重载&quot;">​</a></h4><ol><li>打开<code>lib/main.dart</code>文件。</li><li>将字符串 <code>&#39;You have pushed the button this many times:&#39;</code> 更改为 <code>&#39;You have clicked the button this many times:&#39;</code>。</li><li>不要按“停止”按钮; 让您的应用继续运行。</li><li>要查看您的更改，直接保存（<code>cmd+s</code> / <code>ctrl+s</code>），或者点击 <strong>热重载按钮</strong> （绿色圆形箭头按钮）即可。</li></ol><p>你会立即在运行的应用程序中看到更新的字符串。</p><h2 id="_1-3-3-连接设备运行flutter应用" tabindex="-1">1.3.3 连接设备运行Flutter应用 <a class="header-anchor" href="#_1-3-3-连接设备运行flutter应用" aria-label="Permalink to &quot;1.3.3 连接设备运行Flutter应用&quot;">​</a></h2><p>Window下只支持为Android设备构建并运行Flutter应用，而macOS同时支持iOS和Android设备。下面分别介绍如何连接Android和iOS设备来运行flutter应用。</p><h3 id="_1-连接android模拟器" tabindex="-1">1. 连接Android模拟器 <a class="header-anchor" href="#_1-连接android模拟器" aria-label="Permalink to &quot;1. 连接Android模拟器&quot;">​</a></h3><p>要准备在Android模拟器上运行并测试Flutter应用，请按照以下步骤操作：</p><ol><li><p>启动 <strong>Android Studio&gt;Tools&gt;Android&gt;AVD Manager</strong> 并选择 <strong>Create Virtual Device</strong>.</p></li><li><p>选择一个设备并选择 <strong>Next</strong>。</p></li><li><p>为要模拟的Android版本选择一个或多个系统镜像，然后选择 <strong>Next</strong>. 建议使用 <em>x86</em> 或 <em>x86_64</em> image .</p></li><li><p>在 “Emulated Performance”下, 选择 <strong>Hardware - GLES 2.0</strong> 以启用 <a href="https://developer.android.com/studio/run/emulator-acceleration.html" target="_blank" rel="noreferrer">硬件加速</a>.</p></li><li><p>验证AVD配置是否正确，然后选择 <strong>Finish</strong>。</p><p>有关上述步骤的详细信息，请参阅 <a href="https://developer.android.com/studio/run/managing-avds.html" target="_blank" rel="noreferrer">Managing AVDs</a>.</p></li><li><p>在“Android Virtual Device Manager”中，点击工具栏的 <strong>Run</strong>。模拟器启动并显示所选操作系统版本或设备的启动画面。</p></li><li><p>运行 <code>flutter run</code> 启动您的设备。 连接的设备名是 <code>Android SDK built for &lt;platform&gt;</code>，其中 <em>platform</em> 是芯片系列，如 x86。</p></li></ol><h3 id="_2-连接android真机设备" tabindex="-1">2. 连接Android真机设备 <a class="header-anchor" href="#_2-连接android真机设备" aria-label="Permalink to &quot;2. 连接Android真机设备&quot;">​</a></h3><p>要准备在Android设备上运行并测试Flutter应用，需要Android 4.1（API level 16）或更高版本的Android设备.</p><ol><li>在Android设备上启用 <strong>开发人员选项</strong> 和 <strong>USB调试</strong> 。详细说明可在<a href="https://developer.android.com/studio/debug/dev-options.html" target="_blank" rel="noreferrer">Android文档</a>中找到。</li><li>使用USB将手机插入电脑。如果设备出现调试授权提示，请授权你的电脑可以访问该设备。</li><li>在命令行运行 <code>flutter devices</code> 命令以验证Flutter识别您连接的Android设备。</li><li>运行 <code>flutter run</code> 启动应用程序。</li></ol><p>默认情况下，Flutter使用的Android SDK版本是基于你的 <code>adb</code> 工具版本。 如果想让Flutter使用不同版本的Android SDK，则必须将该 <code>ANDROID_HOME</code> 环境变量设置为相应的SDK安装目录。</p><h3 id="_3-连接ios模拟器" tabindex="-1">3. 连接iOS模拟器 <a class="header-anchor" href="#_3-连接ios模拟器" aria-label="Permalink to &quot;3. 连接iOS模拟器&quot;">​</a></h3><p>要准备在iOS模拟器上运行并测试Flutter应用，请按以下步骤操作：</p><ol><li><p>在你的MAC上，通过 Spotlight 或以下命令找到模拟器：</p><div class="language-shell vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang">shell</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#B392F0;">open</span><span style="color:#E1E4E8;"> </span><span style="color:#79B8FF;">-a</span><span style="color:#E1E4E8;"> </span><span style="color:#9ECBFF;">Simulator</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#6F42C1;">open</span><span style="color:#24292E;"> </span><span style="color:#005CC5;">-a</span><span style="color:#24292E;"> </span><span style="color:#032F62;">Simulator</span></span></code></pre></div></li><li><p>通过检查模拟器 <strong>Hardware &gt; Device</strong> 菜单中的设置，确保模拟器正在使用64位设备（iPhone 5s或更高版本）。</p></li><li><p>根据你电脑屏幕大小，模拟高清屏iOS设备可能会溢出屏幕。可以在模拟器的 <strong>Window&gt; Scale</strong> 菜单下设置设备比例。</p></li><li><p>运行 <code>flutter run</code>启动flutter应用程序。</p></li></ol><h3 id="_4-连接ios真机设备" tabindex="-1">4. 连接iOS真机设备 <a class="header-anchor" href="#_4-连接ios真机设备" aria-label="Permalink to &quot;4. 连接iOS真机设备&quot;">​</a></h3><p>要将Flutter应用安装到iOS真机设备，需要一些额外的工具和一个 Apple 账户，还需要在 Xcode 中进行一些设置。</p><ol><li><p>安装 <a href="http://brew.sh/" target="_blank" rel="noreferrer">homebrew</a> （如果已经安装了brew,跳过此步骤）。</p></li><li><p>打开终端并运行如下这些命令:</p><div class="language-shell vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang">shell</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#B392F0;">brew</span><span style="color:#E1E4E8;"> </span><span style="color:#9ECBFF;">update</span></span>
<span class="line"><span style="color:#B392F0;">brew</span><span style="color:#E1E4E8;"> </span><span style="color:#9ECBFF;">install</span><span style="color:#E1E4E8;"> </span><span style="color:#79B8FF;">--HEAD</span><span style="color:#E1E4E8;"> </span><span style="color:#9ECBFF;">libimobiledevice</span></span>
<span class="line"><span style="color:#B392F0;">brew</span><span style="color:#E1E4E8;"> </span><span style="color:#9ECBFF;">install</span><span style="color:#E1E4E8;"> </span><span style="color:#9ECBFF;">ideviceinstaller</span><span style="color:#E1E4E8;"> </span><span style="color:#9ECBFF;">ios-deploy</span><span style="color:#E1E4E8;"> </span><span style="color:#9ECBFF;">cocoapods</span></span>
<span class="line"><span style="color:#B392F0;">pod</span><span style="color:#E1E4E8;"> </span><span style="color:#9ECBFF;">setup</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#6F42C1;">brew</span><span style="color:#24292E;"> </span><span style="color:#032F62;">update</span></span>
<span class="line"><span style="color:#6F42C1;">brew</span><span style="color:#24292E;"> </span><span style="color:#032F62;">install</span><span style="color:#24292E;"> </span><span style="color:#005CC5;">--HEAD</span><span style="color:#24292E;"> </span><span style="color:#032F62;">libimobiledevice</span></span>
<span class="line"><span style="color:#6F42C1;">brew</span><span style="color:#24292E;"> </span><span style="color:#032F62;">install</span><span style="color:#24292E;"> </span><span style="color:#032F62;">ideviceinstaller</span><span style="color:#24292E;"> </span><span style="color:#032F62;">ios-deploy</span><span style="color:#24292E;"> </span><span style="color:#032F62;">cocoapods</span></span>
<span class="line"><span style="color:#6F42C1;">pod</span><span style="color:#24292E;"> </span><span style="color:#032F62;">setup</span></span></code></pre></div><p>如果这些命令中的任何一个失败并出现错误，请运行brew doctor并按照说明解决问题.</p></li><li><p>遵循Xcode签名流程来配置您的项目:</p><ul><li><p>在你Flutter项目目录中通过 <code>open ios/Runner.xcworkspace</code> 打开默认的Xcode workspace.</p></li><li><p>在Xcode中，选择导航面板左侧中的<code>Runner</code>项目。</p></li><li><p>在<code>Runner</code> target设置页面中，确保在 <strong>General &gt; Signing &gt; Team</strong> 下选择了你的开发团队。当你选择一个团队时，Xcode会创建并下载开发证书，向你的设备注册你的帐户，并创建和下载配置文件（如果需要）。</p></li><li><p>要开始您的第一个iOS开发项目，您可能需要使用您的Apple ID登录Xcode，如图1-4：</p><p><img src="/assets/1-4.da9b4d15.png" alt="图1-4"></p><p>任何Apple ID都支持开发和测试，但若想将应用分发到App Store，就必须注册Apple开发者计划，有关详情读者可以自行了解。</p></li></ul><ol start="4"><li><p>当您第一次attach真机设备进行iOS开发时，需要同时信任你的Mac和该设备上的开发证书。首次将iOS设备连接到Mac时，请在对话框中选择 <code>Trust</code>，如图1-5：</p><p><img src="/assets/1-5.d3e1bec0.png" alt="添加信任"></p><p>然后，转到iOS设备上的<strong>设置</strong>菜单，选择 <strong>常规&gt;设备管理</strong> 并信任您的证书。</p></li><li><p>如果Xcode中的自动签名失败，请验证项目的 <strong>General &gt; Identity &gt; Bundle Identifier</strong> 值是否唯一，如图1-6所示：</p><p><img src="/assets/1-6.b203b389.png" alt="验证bundle id是否唯一"></p></li><li><p>运行 <code>flutter run</code>启动flutter应用程序。</p></li></ol></li></ol><h2 id="_1-3-4-常见配置问题" tabindex="-1">1.3.4 常见配置问题 <a class="header-anchor" href="#_1-3-4-常见配置问题" aria-label="Permalink to &quot;1.3.4 常见配置问题&quot;">​</a></h2><h3 id="_1-android-studio问题" tabindex="-1">1. Android Studio问题 <a class="header-anchor" href="#_1-android-studio问题" aria-label="Permalink to &quot;1. Android Studio问题&quot;">​</a></h3><h4 id="_1-缺少依赖库问题" tabindex="-1">1）缺少依赖库问题 <a class="header-anchor" href="#_1-缺少依赖库问题" aria-label="Permalink to &quot;1）缺少依赖库问题&quot;">​</a></h4><p>上手安卓最常遇见的问题之一，错误如图1-7所示，此时点击超链接即可自动跳转到安装页面</p><p><img src="/assets/1-7.cb1a7167.png" alt="图1-7"></p><p>安装之后重新运行即可，如图1-8：</p><p><img src="/assets/1-8.17dd9d64.png" alt="install_request_components.png"></p><h4 id="_2-连接不上android-repository" tabindex="-1">2）连接不上Android Repository <a class="header-anchor" href="#_2-连接不上android-repository" aria-label="Permalink to &quot;2）连接不上Android Repository&quot;">​</a></h4><p>这也是最常见的问题之一，当你发现自己无法下载部分依赖的时候，请优先考虑这种情况。进入 <code>File</code> -&gt; <code>Settings</code> -&gt; <code>Appearance &amp; Behavior</code> -&gt; <code>System Settings</code> -&gt; <code>Android SDK</code> -&gt; <code>SDK Update Sites</code> 列表，可以看到此时的 <code>Android Repository</code> 无法连接，如图1-9所示：</p><p><img src="/assets/1-9.21a36134.png" alt="下载依赖失败"></p><p>这是由于要去Google下载Android SDK，但在国内目前无法访问Google所致，因此，我们可以配置代理或使用vpn。</p><h4 id="_3-安卓包配置问题" tabindex="-1">3）安卓包配置问题 <a class="header-anchor" href="#_3-安卓包配置问题" aria-label="Permalink to &quot;3）安卓包配置问题&quot;">​</a></h4><p>一般格式为</p><div class="language- vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang"></span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#e1e4e8;">Could not HEAD **</span></span>
<span class="line"><span style="color:#e1e4e8;">Could not Get **</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#24292e;">Could not HEAD **</span></span>
<span class="line"><span style="color:#24292e;">Could not Get **</span></span></code></pre></div><p>如：<code>Android Studio Could not GET gradle-3.2.0.pom</code></p><p>这一类问题是由于无法连接到 Maven 库造成的，解决方法如下：</p><ol><li><p>进入<code>当前所在项目名/android</code></p></li><li><p>打开 <code>build.gradle</code></p></li><li><p>找到下面这一部分，并加上 <code>maven { url &#39;http://maven.aliyun.com/nexus/content/groups/public/&#39; }</code></p><div class="language-groovy vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang">groovy</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#E1E4E8;">allprojects {</span></span>
<span class="line"><span style="color:#E1E4E8;">    repositories {</span></span>
<span class="line"><span style="color:#E1E4E8;">      google()</span></span>
<span class="line"><span style="color:#E1E4E8;">      jcenter()</span></span>
<span class="line"><span style="color:#E1E4E8;">      maven { url </span><span style="color:#9ECBFF;">&#39;http://maven.aliyun.com/nexus/content/groups/public/&#39;</span><span style="color:#E1E4E8;"> } </span><span style="color:#6A737D;">//添加这一句</span></span>
<span class="line"><span style="color:#E1E4E8;">	}</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#24292E;">allprojects {</span></span>
<span class="line"><span style="color:#24292E;">    repositories {</span></span>
<span class="line"><span style="color:#24292E;">      google()</span></span>
<span class="line"><span style="color:#24292E;">      jcenter()</span></span>
<span class="line"><span style="color:#24292E;">      maven { url </span><span style="color:#032F62;">&#39;http://maven.aliyun.com/nexus/content/groups/public/&#39;</span><span style="color:#24292E;"> } </span><span style="color:#6A737D;">//添加这一句</span></span>
<span class="line"><span style="color:#24292E;">	}</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre></div></li><li><p>进入 File/ Settings/ Build, Execution, Deployment/ BuildTools/ Gradle/ Android Studio 中，勾选上 Enable embedded Maven repository ，重启 Android Studio 即可解决。</p><blockquote><p>**注意：**存在这样的一种情况，当你根据上述步骤设置了之后，依旧无法解决这个问题，并有类似于 <code>Could not HEAD maven.aliyun.com</code> 的报错信息，请检查 <code>C:\Users\{user_name}\.gradle\gradle.properties</code> 是否有设置代理。删除后问题即可解决。</p></blockquote></li></ol><h4 id="_4-hot-reload-热重载失效问题" tabindex="-1">4）Hot Reload 热重载失效问题 <a class="header-anchor" href="#_4-hot-reload-热重载失效问题" aria-label="Permalink to &quot;4）Hot Reload 热重载失效问题&quot;">​</a></h4><p>在给 <code>Terminal</code> 之类的终端模拟器设置代理之后，会导致“Hot Reload”重载失效，此时调用 <strong>Save</strong> (<code>cmd-s</code> / <code>ctrl-s</code>)将不会进行热重载，<strong>热重载按钮</strong> (带有闪电⚡️图标的按钮)也不会显示，将代理移除即可解决。</p><p>另外，有些情况下热重载是不生效的，比如修改了<code>main</code>函数、修改了全局静态方法等，读者可以认为“Hot Reload”只会重新构建整个widget树，如果变动不在构建widget树的过程中，“Hot Reload”就不会起作用，这时直接重启 App 就行。</p></div></div></main><footer class="VPDocFooter" data-v-6b87e69f data-v-ef5dee53><!--[--><!--]--><div class="edit-info" data-v-ef5dee53><div class="edit-link" data-v-ef5dee53><a class="VPLink link vp-external-link-icon no-icon edit-link-button" href="https://gitee.com/luoguangguang/note/tree/master/docs/largeFrontEnd/flutter/chapter1/install_flutter.md" target="_blank" rel="noreferrer" data-v-ef5dee53><!--[--><svg xmlns="http://www.w3.org/2000/svg" viewbox="0 0 24 24" class="edit-link-icon" aria-label="edit icon" data-v-ef5dee53><path d="M18,23H4c-1.7,0-3-1.3-3-3V6c0-1.7,1.3-3,3-3h7c0.6,0,1,0.4,1,1s-0.4,1-1,1H4C3.4,5,3,5.4,3,6v14c0,0.6,0.4,1,1,1h14c0.6,0,1-0.4,1-1v-7c0-0.6,0.4-1,1-1s1,0.4,1,1v7C21,21.7,19.7,23,18,23z"></path><path d="M8,17c-0.3,0-0.5-0.1-0.7-0.3C7,16.5,6.9,16.1,7,15.8l1-4c0-0.2,0.1-0.3,0.3-0.5l9.5-9.5c1.2-1.2,3.2-1.2,4.4,0c1.2,1.2,1.2,3.2,0,4.4l-9.5,9.5c-0.1,0.1-0.3,0.2-0.5,0.3l-4,1C8.2,17,8.1,17,8,17zM9.9,12.5l-0.5,2.1l2.1-0.5l9.3-9.3c0.4-0.4,0.4-1.1,0-1.6c-0.4-0.4-1.2-0.4-1.6,0l0,0L9.9,12.5z M18.5,2.5L18.5,2.5L18.5,2.5z"></path></svg> 在Gitee上参与编辑此页<!--]--></a></div><!----></div><nav class="prev-next" data-v-ef5dee53><div class="pager" data-v-ef5dee53><!----></div><div class="pager" data-v-ef5dee53><a class="pager-link next" href="./largeFrontEnd/flutter/chapter1/index.html" data-v-ef5dee53><span class="desc" data-v-ef5dee53>Next page</span><span class="title" data-v-ef5dee53>第一章 初识Flutter</span></a></div></nav></footer><!--[--><!--]--></div></div></div><!--[--><!--]--></div></div><footer class="VPFooter has-sidebar" data-v-1919c326 data-v-e03eb2e1><div class="container" data-v-e03eb2e1><p class="message" data-v-e03eb2e1>Released under the MIT License.</p><p class="copyright" data-v-e03eb2e1>Copyright © 2023-present LG of GZU</p></div></footer><!--[--><!--]--></div></div>
    <script>window.__VP_HASH_MAP__=JSON.parse("{\"backend_index.md\":\"0cb07c7c\",\"largefrontend_electron_index.md\":\"adab8e13\",\"largefrontend_flutter_chapter1_index.md\":\"5106cc23\",\"index.md\":\"20a66851\",\"largefrontend_flutter_chapter10_intro.md\":\"5756d1e8\",\"largefrontend_flutter_chapter10_index.md\":\"87e47f16\",\"largefrontend_flutter_chapter1_flutter_intro.md\":\"9ad5fc78\",\"largefrontend_flutter_chapter12_package_and_plugin.md\":\"c2f14cd7\",\"largefrontend_flutter_chapter12_flutter_web.md\":\"f4b6b743\",\"largefrontend_flutter_chapter10_combine.md\":\"333319d8\",\"largefrontend_flutter_chapter14_flutter_ui_system.md\":\"a1011f7b\",\"largefrontend_flutter_chapter11_index.md\":\"35dcdd7c\",\"largefrontend_flutter_chapter12_index.md\":\"890b799c\",\"largefrontend_flutter_chapter13_index.md\":\"6db9b579\",\"largefrontend_flutter_chapter14_index.md\":\"87f7da6b\",\"largefrontend_flutter_chapter1_mobile_development_intro.md\":\"40c15ac2\",\"largefrontend_flutter_chapter10_turn_box.md\":\"6a792fe1\",\"largefrontend_flutter_chapter3_index.md\":\"bc1d0de5\",\"largefrontend_flutter_chapter4_stack.md\":\"3f5c3186\",\"largefrontend_flutter_chapter1_install_flutter.md\":\"4543c368\",\"largefrontend_flutter_chapter14_paint.md\":\"8f7289b0\",\"largefrontend_flutter_chapter5_padding.md\":\"9fadce05\",\"largefrontend_flutter_chapter4_index.md\":\"f9b298f7\",\"largefrontend_flutter_chapter2_flutter_package_mgr.md\":\"4a3b7161\",\"largefrontend_flutter_chapter11_socket.md\":\"e8264e44\",\"largefrontend_flutter_chapter4_intro.md\":\"1341b5fd\",\"largefrontend_flutter_chapter14_update.md\":\"e4d2c2f0\",\"largefrontend_flutter_chapter5_index.md\":\"455baa0a\",\"largefrontend_flutter_chapter4_alignment.md\":\"a6596610\",\"largefrontend_flutter_chapter13_multi_languages_support.md\":\"c113238d\",\"largefrontend_flutter_chapter11_dio.md\":\"64f4e813\",\"largefrontend_flutter_chapter2_first_flutter_app.md\":\"b650181d\",\"largefrontend_flutter_chapter2_flutter_app_debug.md\":\"67a72433\",\"largefrontend_flutter_chapter2_state_manage.md\":\"9bb80d37\",\"largefrontend_flutter_chapter6_index.md\":\"5a321b81\",\"largefrontend_flutter_chapter5_material_scaffold.md\":\"8e6b896a\",\"largefrontend_flutter_chapter3_buttons.md\":\"ef950360\",\"largefrontend_flutter_chapter10_done_widget.md\":\"c3b44318\",\"largefrontend_flutter_chapter6_single_child_scrollview.md\":\"e3f75f3b\",\"largefrontend_flutter_chapter14_paint_flow.md\":\"d2f8102a\",\"largefrontend_flutter_chapter6_intro.md\":\"125a064e\",\"largefrontend_flutter_chapter5_transform.md\":\"22708e1e\",\"largefrontend_flutter_chapter14_layer.md\":\"4ed449fc\",\"largefrontend_flutter_chapter11_websocket.md\":\"0a022e47\",\"largefrontend_flutter_chapter5_fittedbox.md\":\"db915726\",\"largefrontend_flutter_chapter2_index.md\":\"d8e937b7\",\"largefrontend_flutter_chapter3_radio_and_checkbox.md\":\"025aba21\",\"largefrontend_flutter_chapter13_locallization_implement.md\":\"dc4b83fe\",\"largefrontend_flutter_chapter2_thread_model_and_error_report.md\":\"a29199d6\",\"largefrontend_flutter_chapter5_decoratedbox.md\":\"20f093ba\",\"largefrontend_flutter_chapter14_render_object.md\":\"55a1b551\",\"largefrontend_flutter_chapter14_element_buildcontext.md\":\"4272eae4\",\"largefrontend_flutter_chapter4_wrap_and_flow.md\":\"ac41b5bd\",\"largefrontend_flutter_chapter11_file_operation.md\":\"996a3a5d\",\"largefrontend_flutter_chapter13_faq.md\":\"ba7b9c70\",\"largefrontend_webfrontend_md_10.md\":\"51e0a312\",\"largefrontend_webfrontend_md_24.md\":\"0a4abd08\",\"largefrontend_flutter_chapter14_flutter_app_startup.md\":\"9b5942a1\",\"largefrontend_flutter_chapter10_custom_paint.md\":\"8b2a0a46\",\"largefrontend_flutter_chapter2_flutter_assets_mgr.md\":\"0e38b701\",\"largefrontend_interview_01.md\":\"2ac4b56d\",\"largefrontend_flutter_chapter8_index.md\":\"e83d3d80\",\"largefrontend_webfrontend_md_16.md\":\"a5610416\",\"largefrontend_flutter_chapter9_index.md\":\"3fb342a7\",\"largefrontend_flutter_chapter8_listener.md\":\"1b9b0316\",\"largefrontend_webfrontend_md_37.md\":\"3cacf3a2\",\"largefrontend_flutter_chapter4_layoutbuilder.md\":\"3d4bf94b\",\"largefrontend_webfrontend_md_17.md\":\"ee74edfb\",\"largefrontend_webfrontend_md_13.md\":\"b180bb5b\",\"largefrontend_flutter_chapter7_index.md\":\"0eb456b2\",\"largefrontend_webfrontend_md_31.md\":\"309453c7\",\"largefrontend_webfrontend_md_25.md\":\"95fdb4fe\",\"largefrontend_webfrontend_md_12.md\":\"3b14e491\",\"largefrontend_webfrontend_md_23.md\":\"18f08d72\",\"largefrontend_flutter_chapter11_json_model.md\":\"c84d2ccf\",\"largefrontend_webfrontend_md_01.md\":\"fbb7a35f\",\"largefrontend_flutter_chapter3_progress.md\":\"9bc148d3\",\"largefrontend_webfrontend_md_18.md\":\"ee651cc6\",\"largefrontend_flutter_sponsor.md\":\"e71431a9\",\"largefrontend_webfrontend_md_36.md\":\"f22f6d0d\",\"largefrontend_webfrontend_md_07.md\":\"71c2ad1d\",\"largefrontend_webfrontend_md_19.md\":\"e7907728\",\"largefrontend_webfrontend_md_20.md\":\"5a68bb4f\",\"largefrontend_webfrontend_md_32.md\":\"91d2f39f\",\"largefrontend_flutter_chapter7_futurebuilder_and_streambuilder.md\":\"af3535c0\",\"largefrontend_flutter_chapter9_hero.md\":\"25b46cf2\",\"largefrontend_flutter_chapter8_notification.md\":\"909f6756\",\"largefrontend_webfrontend_md_08.md\":\"0d59dce4\",\"largefrontend_flutter_chapter3_img_and_icon.md\":\"8b409b55\",\"largefrontend_webfrontend_md_04.md\":\"d6c15d55\",\"largefrontend_flutter_chapter9_animated_switcher.md\":\"9c0b3119\",\"largefrontend_webfrontend_md_22.md\":\"7d6fea68\",\"largefrontend_flutter_chapter2_flutter_widget_intro.md\":\"13414fea\",\"largefrontend_flutter_chapter13_intl.md\":\"d4776610\",\"largefrontend_overview_index.md\":\"3c87f69c\",\"largefrontend_flutter_chapter5_container.md\":\"373cc694\",\"largefrontend_wechatminiprogram_index.md\":\"7f40708d\",\"largefrontend_webfrontend_md_38.md\":\"3b6bb332\",\"linux_index.md\":\"624ecc66\",\"largefrontend_webfrontend_md_35.md\":\"f0538423\",\"myteam_index.md\":\"91a2c11f\",\"largefrontend_flutter_chapter6_pageview.md\":\"36fcbc65\",\"largefrontend_webfrontend_md_03.md\":\"2e5087f0\",\"largefrontend_webfrontend_md_21.md\":\"c181316e\",\"largefrontend_flutter_chapter3_input_and_form.md\":\"e4fba9dd\",\"largefrontend_flutter_chapter14_compositing.md\":\"6d96f932\",\"largefrontend_webfrontend_md_29.md\":\"c6fada7d\",\"largefrontend_flutter_chapter4_constraints.md\":\"9e4baace\",\"largefrontend_webfrontend_md_11.md\":\"63cd9c49\",\"largefrontend_webfrontend_md_14.md\":\"1423aeb1\",\"largefrontend_flutter_chapter6_tabview.md\":\"56048fb1\",\"largefrontend_webfrontend_md_33.md\":\"fdbe86fa\",\"largefrontend_flutter_chapter6_nestedscrollview.md\":\"2a66b86a\",\"largefrontend_webfrontend_md_34.md\":\"ad8ea220\",\"largefrontend_flutter_chapter2_flutter_router.md\":\"bb6e776c\",\"largefrontend_webfrontend_md_30.md\":\"cd2cb5aa\",\"largefrontend_flutter_chapter4_flex.md\":\"ebd43d6a\",\"largefrontend_webfrontend_md_09.md\":\"eedafcb1\",\"largefrontend_webfrontend_md_40.md\":\"4d4fefa1\",\"largefrontend_flutter_join_us.md\":\"44c81d86\",\"largefrontend_flutter_chapter9_route_transition.md\":\"f56cf837\",\"largefrontend_uniapp_index.md\":\"fa387c39\",\"largefrontend_flutter_chapter4_row_and_column.md\":\"964229f5\",\"largefrontend_flutter_chapter9_stagger_animation.md\":\"315538f5\",\"largefrontend_flutter_chapter3_text.md\":\"6720230c\",\"largefrontend_flutter_chapter10_watermark.md\":\"2e4ddf03\",\"largefrontend_flutter_chapter11_http.md\":\"efd2ee64\",\"largefrontend_webfrontend_md_06.md\":\"e20b049a\",\"largefrontend_flutter_summary.md\":\"2e31b0a8\",\"largefrontend_flutter_chapter6_animatedlist.md\":\"20d9436f\",\"largefrontend_flutter_chapter5_clip.md\":\"91f4174c\",\"largefrontend_webfrontend_md_02.md\":\"40cd2099\",\"largefrontend_flutter_chapter6_gridview.md\":\"b3be7e60\",\"largefrontend_flutter_chapter6_custom_scrollview.md\":\"01be950c\",\"largefrontend_flutter_chapter11_download_with_chunks.md\":\"9379cc89\",\"largefrontend_flutter_chapter6_scroll_controller.md\":\"ffa2d5fd\",\"largefrontend_flutter_chapter9_intro.md\":\"3fc29b5f\",\"largefrontend_flutter_chapter1_dart.md\":\"6bba4e7c\",\"largefrontend_flutter_chapter7_inherited_widget.md\":\"5a21d704\",\"largefrontend_flutter_index.md\":\"cd81fbbe\",\"largefrontend_flutter_reference.md\":\"36336375\",\"largefrontend_flutter_chapter6_keepalive.md\":\"535137be\",\"largefrontend_flutter_chapter14_layout.md\":\"0d7a8df3\",\"largefrontend_flutter_chapter6_sliver.md\":\"0c8b7553\",\"largefrontend_webfrontend_md_39.md\":\"aef49a57\",\"largefrontend_webfrontend_md_15.md\":\"bf9ff1a1\",\"largefrontend_flutter_chapter14_image_and_cache.md\":\"9622c56b\",\"largefrontend_webfrontend_md_28.md\":\"83169d10\",\"largefrontend_flutter_chapter8_eventbus.md\":\"fc0db86d\",\"largefrontend_flutter_chapter7_value_listenable_builder.md\":\"a0c76121\",\"largefrontend_flutter_preface.md\":\"604b9934\",\"largefrontend_flutter_chapter7_theme.md\":\"c21036bc\",\"largefrontend_webfrontend_md_05.md\":\"f7607009\",\"largefrontend_flutter_chapter6_listview.md\":\"472910bd\",\"largefrontend_flutter_chapter7_provider.md\":\"ab590744\",\"largefrontend_flutter_chapter8_gesture.md\":\"859bbb38\",\"largefrontend_flutter_chapter9_animated_widgets.md\":\"e8cd3c4d\",\"largefrontend_webfrontend_md_26.md\":\"4928006b\",\"largefrontend_flutter_chapter10_gradient_circular_progress_demo.md\":\"b3d48a2c\",\"largefrontend_flutter_chapter8_hittest.md\":\"e963812b\",\"largefrontend_flutter_chapter7_willpopscope.md\":\"d224ecce\",\"largefrontend_flutter_chapter9_animation_structure.md\":\"672eb3c0\",\"largefrontend_flutter_chapter8_gesture_conflict.md\":\"15bbadba\",\"largefrontend_webfrontend_md_27.md\":\"0b5b5e39\",\"largefrontend_flutter_chapter7_dailog.md\":\"5f91e51a\",\"largefrontend_flutter_chapter10_custom_checkbox.md\":\"0db7d50f\"}");window.__VP_SITE_DATA__=JSON.parse("{\"lang\":\"zh-CN\",\"dir\":\"ltr\",\"title\":\"落光的Pro博客\",\"description\":\"Vite & Vue powered static site generator.\",\"base\":\"./\",\"head\":[],\"appearance\":true,\"themeConfig\":{\"search\":{\"provider\":\"local\",\"options\":{\"locales\":{\"zh\":{\"translations\":{\"button\":{\"buttonText\":\"搜索文档\",\"buttonAriaLabel\":\"搜索文档\"},\"modal\":{\"noResultsText\":\"无法找到相关结果\",\"resetButtonTitle\":\"清除查询条件\",\"footer\":{\"selectText\":\"选择\",\"navigateText\":\"切换\"}}}}}}},\"logo\":\"/icon-radius.png\",\"nav\":[{\"text\":\"大前端\",\"items\":[{\"text\":\"Web前端\",\"link\":\"/largeFrontEnd/webFrontEnd/md/01.md\"},{\"text\":\"Uni-app\",\"link\":\"/largeFrontEnd/uniapp/\"},{\"text\":\"微信小程序\",\"link\":\"/largeFrontEnd/weChatMiniProgram/\"},{\"text\":\"Electron\",\"link\":\"/largeFrontEnd/electron/\"},{\"text\":\"Flutter\",\"link\":\"/largeFrontEnd/flutter/\"},{\"text\":\"前端面试题\",\"link\":\"/largeFrontEnd/interview/01.md\"}]},{\"text\":\"后端\",\"link\":\"/backEnd/\"},{\"text\":\"Linux\",\"link\":\"/linux/\"},{\"text\":\"我的团队\",\"link\":\"/myTeam/\"}],\"sidebar\":{\"/largeFrontEnd/webFrontEnd/\":[{\"text\":\"第一阶段  基础入门\",\"collapsed\":true,\"items\":[{\"text\":\"一、基础认知\",\"link\":\"/largeFrontEnd/webFrontEnd/md/01.md\"},{\"text\":\"二、HTML标签学习\",\"link\":\"/largeFrontEnd/webFrontEnd/md/02.md\"},{\"text\":\"三、HTML基础\",\"link\":\"/largeFrontEnd/webFrontEnd/md/03.md\"},{\"text\":\"四、CSS基础\",\"link\":\"/largeFrontEnd/webFrontEnd/md/04.md\"},{\"text\":\"五、CSS进阶\",\"link\":\"/largeFrontEnd/webFrontEnd/md/05.md\"},{\"text\":\"六、盒子模型\",\"link\":\"/largeFrontEnd/webFrontEnd/md/06.md\"},{\"text\":\"七、CSS浮动\",\"link\":\"/largeFrontEnd/webFrontEnd/md/07.md\"},{\"text\":\"八、CSS定位装饰\",\"link\":\"/largeFrontEnd/webFrontEnd/md/08.md\"},{\"text\":\"九、CSS精灵图\",\"link\":\"/largeFrontEnd/webFrontEnd/md/09.md\"},{\"text\":\"项目前置认知\",\"link\":\"/largeFrontEnd/webFrontEnd/md/10.md\"},{\"text\":\"项目结构搭建\",\"link\":\"/largeFrontEnd/webFrontEnd/md/11.md\"},{\"text\":\"字体图标、动画\",\"link\":\"/largeFrontEnd/webFrontEnd/md/12.md\"},{\"text\":\"移动web开发\",\"link\":\"/largeFrontEnd/webFrontEnd/md/13.md\"}]},{\"text\":\"第二阶段 技术进阶\",\"collapsed\":true,\"items\":[{\"text\":\"JavaScript深入浅出\",\"link\":\"/largeFrontEnd/webFrontEnd/md/14.md\"},{\"text\":\"JavaScript核心之web APIs\",\"link\":\"/largeFrontEnd/webFrontEnd/md/15.md\"},{\"text\":\"一、Web APIS导读\",\"link\":\"/largeFrontEnd/webFrontEnd/md/16.md\"},{\"text\":\"二、DOM导读\",\"link\":\"/largeFrontEnd/webFrontEnd/md/17.md\"},{\"text\":\"三、事件高级导读\",\"link\":\"/largeFrontEnd/webFrontEnd/md/18.md\"},{\"text\":\"四、BOM导读\",\"link\":\"/largeFrontEnd/webFrontEnd/md/19.md\"},{\"text\":\"五、PC网页特效导读\",\"link\":\"/largeFrontEnd/webFrontEnd/md/20.md\"},{\"text\":\"六、移动端特效导读\",\"link\":\"/largeFrontEnd/webFrontEnd/md/21.md\"},{\"text\":\"七、本地存储导读\",\"link\":\"/largeFrontEnd/webFrontEnd/md/22.md\"},{\"text\":\"jQuery入门导读\",\"link\":\"/largeFrontEnd/webFrontEnd/md/23.md\"},{\"text\":\"数据可视化项目导读\",\"link\":\"/largeFrontEnd/webFrontEnd/md/24.md\"}]},{\"text\":\"Node.js\",\"collapsed\":true,\"items\":[{\"text\":\"buffer(缓冲器)\",\"link\":\"/largeFrontEnd/webFrontEnd/md/25.md\"},{\"text\":\"计算机基础\",\"link\":\"/largeFrontEnd/webFrontEnd/md/26.md\"},{\"text\":\"fs模块\",\"link\":\"/largeFrontEnd/webFrontEnd/md/27.md\"},{\"text\":\"path模块\",\"link\":\"/largeFrontEnd/webFrontEnd/md/28.md\"},{\"text\":\"HTTP模块\",\"link\":\"/largeFrontEnd/webFrontEnd/md/29.md\"},{\"text\":\"Express框架\",\"link\":\"/largeFrontEnd/webFrontEnd/md/30.md\"},{\"text\":\"Mongodb\",\"link\":\"/largeFrontEnd/webFrontEnd/md/31.md\"}]},{\"text\":\"Ajax\",\"link\":\"/largeFrontEnd/webFrontEnd/md/32.md\"},{\"text\":\"前端面试题\",\"collapsed\":true,\"items\":[{\"text\":\"一、CSS\",\"link\":\"/largeFrontEnd/webFrontEnd/md/33.md\"},{\"text\":\"二、JavaScript\",\"link\":\"/largeFrontEnd/webFrontEnd/md/34.md\"},{\"text\":\"三、HTML5CSS3\",\"link\":\"/largeFrontEnd/webFrontEnd/md/35.md\"},{\"text\":\"四、Vue\",\"link\":\"/largeFrontEnd/webFrontEnd/md/36.md\"},{\"text\":\"五、Echarts\",\"link\":\"/largeFrontEnd/webFrontEnd/md/37.md\"},{\"text\":\"六.Uni-APP\",\"link\":\"/largeFrontEnd/webFrontEnd/md/38.md\"},{\"text\":\"七、webpack\",\"link\":\"/largeFrontEnd/webFrontEnd/md/39.md\"},{\"text\":\"八、Git\",\"link\":\"/largeFrontEnd/webFrontEnd/md/40.md\"}]}],\"/largeFrontEnd/flutter/\":[{\"text\":\"Flutter入门到实战\",\"collapsed\":false,\"items\":[{\"text\":\"第一章 初识Flutter\",\"link\":\"/largeFrontEnd/flutter/chapter1/index.md\"},{\"text\":\"第二章 简介\",\"link\":\"/largeFrontEnd/flutter/chapter2/index.md\"},{\"text\":\"第三章 基础组件\",\"link\":\"/largeFrontEnd/flutter/chapter3/index.md\"},{\"text\":\"第四章 布局类组件\",\"link\":\"/largeFrontEnd/flutter/chapter4/index.md\"},{\"text\":\"第五章 容器类Widget\",\"link\":\"/largeFrontEnd/flutter/chapter5/index.md\"},{\"text\":\"第六章 可滚动组件\",\"link\":\"/largeFrontEnd/flutter/chapter6/index.md\"},{\"text\":\"第七章 功能型Widget简介\",\"link\":\"/largeFrontEnd/flutter/chapter7/index.md\"},{\"text\":\"第八章 事件处理与通知\",\"link\":\"/largeFrontEnd/flutter/chapter8/index.md\"},{\"text\":\"第九章 动画\",\"link\":\"/largeFrontEnd/flutter/chapter9/index.md\"},{\"text\":\"第十章 自定义组件\",\"link\":\"/largeFrontEnd/flutter/chapter10/index.md\"},{\"text\":\"第十一章 文件操作\",\"link\":\"/largeFrontEnd/flutter/chapter11/index.md\"},{\"text\":\"第十二章 Flutter 扩展\",\"link\":\"/largeFrontEnd/flutter/chapter12/index.md\"},{\"text\":\"第十三章 多语言\",\"link\":\"/largeFrontEnd/flutter/chapter13/index.md\"},{\"text\":\"第十四章 高级进阶\",\"link\":\"/largeFrontEnd/flutter/chapter14/index.md\"}]}]},\"socialLinks\":[{\"icon\":\"github\",\"link\":\"https://gitee.com/luoguangguang\"},{\"icon\":{\"svg\":\"<svg role=\\\"img\\\" viewBox=\\\"0 0 24 24\\\" xmlns=\\\"http://www.w3.org/2000/svg\\\"><title>Dribbble</title><path d=\\\"M12...6.38z\\\"/></svg>\"},\"link\":\"...\",\"ariaLabel\":\"cool link\"}],\"footer\":{\"message\":\"Released under the MIT License.\",\"copyright\":\"Copyright © 2023-present LG of GZU\"},\"editLink\":{\"pattern\":\"https://gitee.com/luoguangguang/note/tree/master/docs/:path\",\"text\":\"在Gitee上参与编辑此页\"},\"carbonAds\":{\"code\":\"your-carbon-code\",\"placement\":\"your-carbon-placement\"}},\"locales\":{},\"scrollOffset\":90,\"cleanUrls\":false}");</script>
    
  </body>
</html>